#ifndef SETTINGSMENU_H
#define SETTINGSMENU_H

#include <QKeySequence>
#include <QList>
#include <QPair>
#include <QString>
#include <QTabWidget>

class QDialog;

namespace Ui {
    class SettingsMenu;
}

class SettingsMenu : public QTabWidget
{
    Q_OBJECT

public:
    explicit SettingsMenu(QWidget *parent = 0);
    ~SettingsMenu();

    QKeySequence getKey();

public slots:
    void reloadPlugins();
    void onOkButtonClicked();
    void onOptionsButtonClicked();
    void onAboutButtonClicked();

    bool eventFilter(QObject* obj, QEvent* event);
    void setKey(const QKeySequence& key);

private:
    QList<QPair<QString, QString> > pluginsList;

    Ui::SettingsMenu *ui;
    void LoadConfig();
    void setConnections();
    QDialog* settingsWindowDraft;
    void constructSettingsWindowDraft();

    QString selectedPluginFileName();

signals:
    void hotkeyLineEditHasBeenChanged(const QKeySequence& key);

};

#endif // SETTINGSMENU_H
